<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div class="my-elements"></div>
    <script>
        const myElements = document.querySelectorAll('.my-elements');
        console.log(myElements);
        const arr = Array.from(myElements);
        console.log(arr);
        //Array.prototype.slice.call() 
        const arr1 = Array.prototype.slice.call(myElements);
        console.log(arr1);
        //Spread operator
        const arr2 = [...myElements];
        console.log(arr2);
    </script>    
</body>
</html>